<?php
/**
 * Created by PhpStorm.
 * User: Lihong
 * Date: 2017/8/26
 * Time: 12:36
 */
use yii\helpers\Url;
?>
<div class="table-responsive">
  <table class="table table-bordered">
      <tr>
        <th>用户ID</th>
        <th>用户昵称</th>
        <th>用户邮箱</th>
        <th>用户组</th>
        <th>用户状态</th>
        <th>登陆时间</th>
        <th>登陆IP</th>
        <th>操作</th>
      </tr>
      <?php foreach ($lists as $key => $value){?>
          <tr>
              <td><?=$value['id']?></td>
              <td><?=$value['nick_name']?></td>
              <td><?=$value['email']?></td>
              <td><?=$value['role']?></td>
              <td><?=$value['status']?></td>
              <td><?=$value['last_login']?></td>
              <td><?=$value['last_ip']?></td>
              <td>
                  <a class="btn btn-info" href="<?=Url::to(['user/view', 'id' => $value['id']])?>">查看</a>
                  <a class="btn btn-warning" href="<?=Url::to(['user/edit', 'id' => $value['id']])?>">更新</a>
                  <a class="btn btn-danger" href="<?=Url::to(['user/del', 'id' => $value['id']])?>">删除</a>
              </td>
          </tr>
      <?php } ?>
  </table>
</div>